//
//  MyAlertController.swift
//  xiaoqiao
//
//  Created by 冷子豪 on 2017/8/9.
//  Copyright © 2017年 冷子豪. All rights reserved.
//

import UIKit

class MyAlertController: UIAlertController {

    override func viewDidLoad() {
        super.viewDidLoad()
        
        // message 字体样式（20号 红色）
        let messageFont = UIFont.systemFont(ofSize: 20)
        let messageAttribute = NSMutableAttributedString.init(string: self.message!)
        messageAttribute.addAttributes([NSFontAttributeName:messageFont,
                                        NSForegroundColorAttributeName:UIColor.red],
                                       range:NSMakeRange(0, (self.message?.characters.count)!))
        self.setValue(messageAttribute, forKey: "attributedMessage")
    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }
    

}
